package com.kb.design.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 *
 *
 * @author makejava
 * @since 2024-04-24 15:45:23
 */
@Data
@TableName("design_responsible_person")
@Accessors(chain = true)
public class DesignResponsiblePerson implements Serializable {
    private static final long serialVersionUID = 412275626418653306L;

    @TableId(type = IdType.AUTO)
    private Long id;

    /**
     * 项目id
     */
    @NotNull(message = "项目id不能为空", groups = {addGroup.class})
    private Long projectId;

    /**
     * 负责人id
     */
    @TableField("responsible_person_id")
    private String responsiblePersonId;

    /**
     * 设计任务状态 10:封装 20:设计
     */
    @TableField("node_status")
    private String nodeStatus;

    /**
     * 是否删除
     */
    private String del;

    /**
     * 创建时间
     */
    @TableField(fill = FieldFill.INSERT)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime createTime;

    /**
     * 创建人
     */
    @TableField("create_by")
    private String createBy;

    /**
     * 更新时间
     */
    @TableField(fill = FieldFill.INSERT_UPDATE)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime updateTime;

    /**
     * 更新人
     */
    @TableField("update_by")
    private String updateBy;

    /**
     * 备注
     */
    @TableField("remark")
    private String remark;

    /**
     * 完成率
     */
    @TableField("completion_rate")
    private String completionRate;

    /**
     * 是否完成 1未 2完成
     */
    @TableField("is_complete")
    private Integer isComplete;
    private String deptName;

    /**
     * 完成时间
     */
    @TableField("complete_time")
    private LocalDateTime completeTime;

    /**
     * 负责人名称
     */
    @TableField("responsible_person_name")
    private String responsiblePersonName;


    /**
     * 人员类型  1 主管 2 工程师
     */
    @TableField("person_type")
    private Integer personType;

    @TableField(exist = false)
    private String projectNumber;
    @TableField(exist = false)
    private String relevantResponsiblePerson;
    @TableField(exist = false)
    private String status;

    @TableField(exist = false)
    private String type;

    @TableField(exist = false)
    private Integer designDepartments;
    private Integer deptId;
    public interface addGroup { }
}

